A comprehensive collection of laboratory exercises and theoretical materials for computer networks study.
| Exercise | Folder | Description |
|---|---|---|
| EP0 | Laboratory/EP0/ |
Network packet analysis and PCAP file examination |
| EP1 | Laboratory/EP1/ |
MQTT server implementation and performance testing |
| EP2 | Laboratory/EP2/ |
Secure client-server game with encryption |
| EP3 | Laboratory/EP3/ |
Firewall implementation and network switching |
| EP4 | Laboratory/EP4/ |
Advanced networking concepts |
Location: Laboratory/EP0/
This exercise focuses on network packet analysis using PCAP files. It includes:
pergunta.pcapng- Primary packet capture file for analysisep0-arthur_font_gouveia/- Solutions and detailed responsespergunta2.pcapng- Additional packet capture filerespostas.txt- Answers and analysis results
Topics Covered:
- Packet capture and analysis
- Network traffic examination
- Protocol identification
Location: Laboratory/EP1/
Implementation of an MQTT server with performance analysis. Includes:
bash.sh- Utility bash scriptsep1-arthur_font_gouveia/- Solution implementationep1-mqtt-server.c- MQTT server implementationdesempenho.c- Performance testing moduleMakefile- Build configurationREADME.md- Detailed exercise documentation
Prints/- Test output and results
Topics Covered:
- MQTT protocol implementation
- Server socket programming
- Performance benchmarking
- C networking fundamentals
Location: Laboratory/EP2/
A complete client-server game implementation with encryption and security. Includes:
main.py- Main entry pointclient/- Client-side codeclient.py- Client implementationgame.py- Game logic
server/- Server-side codeserver.py- Server implementationconnection.py- Connection managementuser.py- User managementreboot.py- Server restart utilitiesdata/- Data storage
perm/- Cryptographic keyssk.pem- Private keypk.pem- Public key
scripts/- Testing and automationmatch.sh- Game match runnerplayer1,player2- Player scripts
Topics Covered:
- Client-server architecture
- Encryption and SSL/TLS
- Public key cryptography
- Python socket programming
- Game protocol design
Location: Laboratory/EP3/
Network firewall and switch implementation with configuration rules. Includes:
firewall.py- Firewall implementationswitch.py- Network switch implementationrules.json- Firewall rules configurationmac0352-relatorio-ep3.tex- LaTeX report documentep3-arthur_font_gouveia/- Solution directory withREADME.md
Topics Covered:
- Firewall rule processing
- Network packet filtering
- Layer 2 switching
- Network security policies
- Rule configuration and management
Location: Laboratory/EP4/
This exercise focuses on exploring and understanding real-world network security vulnerabilities. The objective is to identify a programming flaw that leads to a vulnerability, demonstrate and explain its exploitation and patch.
Vulnerability Studied: CVE-2020-8794
- Type: Out-of-bounds buffer read in DNS protocol parsing
- Affected Component: DNS response message handling
- Root Cause: Improper boundary checking when parsing three-digit DNS response codes without optional space and text
- Attack Vector: Malicious DNS server (client-side) or malicious DNS client (server-side)
- Impact: Buffer overflow leading to information disclosure or potential code execution
Files:
Arthur_Lucas_EP4.pdf- Complete study and analysis reportEP4.txt- Exercise description and requirementsRoteiro.pdf- Presentation overview- Supporting images:
codigo.png- Vulnerable code snippetpatch.png- Patched/fixed codeenvelope.png- DNS message envelope structureenv malicioso.png- Malicious envelope construction
Topics Covered:
- Network security vulnerabilities (CVE analysis)
- DNS protocol exploitation techniques
- Buffer overflow vulnerabilities
- Out-of-bounds memory access
- Vulnerability remediation and secure patching
- Root cause analysis of programming flaws
- EP2 Repository: https://github.com/Agfont/Networks-EP2